import os
import sys

from libavg import avg, AVGApp
from config import Config
from display import Display
from simulator import Simulator
import random

sys.path.append('panels')
sys.path.append('../data')
sys.path.append('../data/img')

# Usually you need the Player in many places, so it's useful
# to keep it in a global variable (it's a singleton anyway).
g_player = avg.Player.get()

class Main(AVGApp):
            
    def __init__(self, parentNode):
        g_player.enableMultitouch() # SCHALTE MULTITOUCH EIN
        self.sim = Simulator(parentNode.size, parentNode) # BAUE SIMULATOR
        
    def _enter(self):
        self.sim.start(); # STARTE SIMULATOR WENN PROGRAMM SICHTBAR
            
Main.start(resolution=(Config.resX, Config.resY)) 

